home *** CD-ROM | disk | FTP | other *** search
/ 3D Game Programming All in One / 3D Game Programming All in One Disc.iso / 3D2E / RESOURCES / CH20 / creator / ui / InspectDlg.gui < prev   
Text File  |  2005-11-23  |  5KB  |  205 lines

  1. //--- OBJECT WRITE BEGIN ---
  2. new GuiControl(InspectDlg) {
  3.     profile = "GuiDialogProfile";
  4.     horizSizing = "right";
  5.     vertSizing = "bottom";
  6.     position = "0 0";
  7.     extent = "640 480";
  8.     minExtent = "8 8";
  9.     visible = "True";
  10.     setFirstResponder = "False";
  11.     modal = "False";
  12.     helpTag = "0";
  13.  
  14.     new GuiWindowCtrl(InspectTitle) {
  15.         profile = "GuiWindowProfile";
  16.         horizSizing = "right";
  17.         vertSizing = "bottom";
  18.         position = "20 20";
  19.         extent = "200 400";
  20.         minExtent = "8 8";
  21.         visible = "True";
  22.         setFirstResponder = "False";
  23.         modal = "True";
  24.         helpTag = "0";
  25.         resizeWidth = "True";
  26.         resizeHeight = "True";
  27.         canMove = "True";
  28.         canClose = "True";
  29.         canMinimize = "True";
  30.         canMaximize = "True";
  31.         minSize = "50 50";
  32.         closeCommand = "Canvas.popDialog(InspectDlg);";
  33.             font = "12 244 Arial";
  34.             selectfillColor = "253";
  35.             fillColor = "250";
  36.             opaque = "true";
  37.  
  38.         new GuiButtonCtrl() {
  39.             profile = "GuiButtonProfile";
  40.             horizSizing = "right";
  41.             vertSizing = "bottom";
  42.             position = "8 24";
  43.             extent = "40 16";
  44.             minExtent = "8 8";
  45.             visible = "True";
  46.             setFirstResponder = "False";
  47.             modal = "True";
  48.             command = "InspectApply();";
  49.             helpTag = "0";
  50.             text = "APPLY";
  51.                 selectBorderColor = "255";
  52.                 borderColor = "249";
  53.                 fillColor = "249";
  54.                 fontHL = "12 253 Arial";
  55.                 font = "12 252 Arial";
  56.         };
  57.         new GuiTextCtrl() {
  58.             profile = "GuiTextProfile";
  59.             horizSizing = "right";
  60.             vertSizing = "bottom";
  61.             position = "56 24";
  62.             extent = "29 18";
  63.             minExtent = "8 8";
  64.             visible = "True";
  65.             setFirstResponder = "False";
  66.             modal = "True";
  67.             helpTag = "0";
  68.             text = "Name:";
  69.                 font = "12 244 Arial";
  70.         };
  71.         new GuiTextEditCtrl(InspectObjectName) {
  72.             profile = "GuiTextEditProfile";
  73.             horizSizing = "width";
  74.             vertSizing = "bottom";
  75.             position = "98 23";
  76.             extent = "72 18";
  77.             minExtent = "8 8";
  78.             visible = "True";
  79.             setFirstResponder = "False";
  80.             modal = "True";
  81.             helpTag = "0";
  82.             historySize = "0";
  83.         };
  84.         new GuiScrollCtrl() {
  85.             profile = "GuiScrollProfile";
  86.             horizSizing = "width";
  87.             vertSizing = "height";
  88.             position = "8 44";
  89.             extent = "184 348";
  90.             minExtent = "8 8";
  91.             visible = "True";
  92.             setFirstResponder = "False";
  93.             modal = "True";
  94.             helpTag = "0";
  95.             willFirstRespond = "True";
  96.             hScrollBar = "alwaysOff";
  97.             vScrollBar = "alwaysOn";
  98.             constantThumbHeight = "False";
  99.  
  100.             new GuiInspector(InspectFields) {
  101.                 profile = "GuiDefaultProfile";
  102.                 horizSizing = "width";
  103.                 vertSizing = "bottom";
  104.                 position = "0 0";
  105.                 extent = "184 8";
  106.                 minExtent = "8 8";
  107.                 visible = "True";
  108.                 setFirstResponder = "False";
  109.                 modal = "True";
  110.                 helpTag = "0";
  111.             };
  112.         };
  113.     };
  114.     new GuiWindowCtrl(InspectTreeTitle) {
  115.         profile = "GuiWindowProfile";
  116.         horizSizing = "right";
  117.         vertSizing = "bottom";
  118.         position = "232 20";
  119.         extent = "200 400";
  120.         minExtent = "8 8";
  121.         visible = "True";
  122.         setFirstResponder = "False";
  123.         modal = "True";
  124.         helpTag = "0";
  125.         text = "TREE VIEW";
  126.         resizeWidth = "True";
  127.         resizeHeight = "True";
  128.         canMove = "True";
  129.         canClose = "True";
  130.         canMinimize = "True";
  131.         canMaximize = "True";
  132.         minSize = "50 50";
  133.         closeCommand = "Canvas.popDialog(InspectDlg);";
  134.  
  135.         new GuiScrollCtrl() {
  136.             profile = "GuiScrollProfile";
  137.             horizSizing = "width";
  138.             vertSizing = "height";
  139.             position = "8 24";
  140.             extent = "184 368";
  141.             minExtent = "8 8";
  142.             visible = "True";
  143.             setFirstResponder = "False";
  144.             modal = "True";
  145.             helpTag = "0";
  146.             willFirstRespond = "True";
  147.             hScrollBar = "dynamic";
  148.             vScrollBar = "alwaysOn";
  149.             constantThumbHeight = "False";
  150.  
  151.             new GuiTreeViewCtrl(InspectTreeView) {
  152.                 profile = "GuiTreeViewProfile";
  153.                 horizSizing = "width";
  154.                 vertSizing = "bottom";
  155.                 position = "0 0";
  156.                 extent = "64 64";
  157.                 minExtent = "8 8";
  158.                 visible = "True";
  159.                 setFirstResponder = "False";
  160.                 modal = "True";
  161.                 helpTag = "0";
  162.                 destroyTreeOnSleep = false;
  163.             };
  164.         };
  165.     };
  166. };
  167. //--- OBJECT WRITE END ---
  168.  
  169. function Inspect(%obj)
  170. {
  171.    Canvas.popDialog("InspectDlg");
  172.    Canvas.pushDialog("InspectDlg", 30);
  173.    
  174.    InspectFields.inspect(%obj);
  175.    InspectObjectName.setValue(%obj.getName());
  176.    InspectTitle.setValue(%obj.getId() @ ": " @ %obj.getName());
  177. }
  178.  
  179. function InspectApply()
  180. {
  181.    InspectFields.apply(InspectObjectName.getValue());
  182. }
  183.  
  184. function InspectTreeView::onSelect(%this, %obj)
  185. {
  186.    Inspect(%obj);
  187. }
  188.  
  189. function Tree(%obj)
  190. {
  191.    Canvas.popDialog("InspectDlg");
  192.    Canvas.pushDialog("InspectDlg", 35);
  193.    InspectTreeView.open(%obj);
  194. }
  195.  
  196. function InspectAddFieldDlg::doAction(%this)
  197. {
  198.    if(InspectAddFieldName.getValue() $= "" || InspectAddFieldValue.getValue() $= "")
  199.       return;
  200.    eval(%this.object @ "." @ firstWord(InspectAddFieldName.getValue()) @ " = " @ InspectAddFieldValue.getValue() @ ";");
  201.    %this.inspector.inspect(%this.object);
  202. }
  203.  
  204.  
  205.